﻿@model ChargeServiceViewModel
@{
    ViewData.SetLayoutModel(new LayoutModel(nameof(ServerNavPages.Services), StringLocalizer["Lightning Charge Service"])
        .SetCategory(WellKnownCategories.Server));
}

<div class="sticky-header">
    <nav aria-label="breadcrumb">
        <ol class="breadcrumb">
            <li class="breadcrumb-item">
                <a asp-action="Services" text-translate="true">Services</a>
            </li>
            <li class="breadcrumb-item active" aria-current="page">@ViewData["Title"]</li>
        </ol>
        <h2>@ViewData["Title"]</h2>
    </nav>
</div>
<partial name="_StatusMessage" />

<div class="row">
    <div class="col-md-8">
        @if (!ViewContext.ModelState.IsValid)
        {
            <div asp-validation-summary="All"></div>
        }
        <div class="form-group">
            <p text-translate="true">Lightning charge is a simple API for invoicing on lightning network, you can use it with several plugins:</p>
            <ul>
                <li><a href="https://github.com/ElementsProject/woocommerce-gateway-lightning" target="_blank" rel="noreferrer noopener">WooCommerce Lightning Gateway</a>: A comprehensive e-commerce application that integrates with stock-management and order-tracking systems</li>
                <li><a href="https://github.com/ElementsProject/nanopos" target="_blank" rel="noreferrer noopener">Nanopos</a>: A simple point-of-sale system for fixed-price goods</li>
                <li><a href="https://github.com/ElementsProject/filebazaar" target="_blank" rel="noreferrer noopener">FileBazaar</a>: A system for selling files such as documents, images, and videos</li>
                <li><a href="https://github.com/ElementsProject/wordpress-lightning-publisher" target="_blank" rel="noreferrer noopener">Lightning Publisher for WordPress</a>: A patronage model for unlocking WordPress blog entries</li>
                <li><a href="https://github.com/ElementsProject/paypercall" target="_blank" rel="noreferrer noopener">Paypercall</a>: A programmer’s toolkit for Lightning that enables micropayments for individual API calls</li>
                <li><a href="https://github.com/ElementsProject/ifpaytt" target="_blank" rel="noreferrer noopener">Ifpaytt</a>: An extension of paypercall that allows web developers using IFTTT to request payments for service usage</li>
                <li><a href="https://github.com/ElementsProject/lightning-jukebox" target="_blank" rel="noreferrer noopener">Lightning Jukebox</a>: A fun demo that reimagines a classic technology for the Lightning Network</li>
                <li><a href="https://github.com/ElementsProject/nanotip" target="_blank" rel="noreferrer noopener">Nanotip</a>: The simple tip jar, rebuilt to issue Lightning Network invoices</li>
            </ul>
        </div>
    </div>
</div>
<div class="row">
    <div class="col-md-8">
        <h4 text-translate="true">Credentials</h4>
        @if (Model.Uri != null)
        {
            <div class="form-group">
                <label asp-for="Uri" class="form-label"></label>
                <input asp-for="Uri" class="form-control" readonly />
            </div>
        }
        @if (Model.APIToken != null)
        {
            <div class="form-group">
                <label asp-for="APIToken" class="form-label"></label>
                <input asp-for="APIToken" class="form-control" readonly />
            </div>
        }
        @if (Model.AuthenticatedUri != null)
        {
            <div class="form-group">
                <label asp-for="AuthenticatedUri" class="form-label"></label>
                <input asp-for="AuthenticatedUri" class="form-control" readonly />
            </div>
        }
    </div>
</div>
